#ifndef GEO_ENTITY_H
#define GEO_ENTITY_H
#include "Def.h"
#include "Property.h"

class GeoEntityPrivate;
class GeoEntity : public IVisible,public NamedObject,public IPropertySet,public IDeleter
{
public:
    virtual ~GeoEntity();
public:
	void setGeoPoint(double lon,double lat,double alt)
	{
	    setGeoLon(lon);	
		setGeoLat(lat);
		setGeoAlt(alt);
	}
	
	double getGeoLon()const;
	double getGeoLat()const;
	double getGeoAlt()const;

	void setGeoLon(double lon);
	void setGeoLat(double lat);
	void setGeoAlt(double alt);
public:
	void setHeading(double heading);
	double getHeading()const;
	
	void setPitch(double pitch);
	double getPitch()const;
	
	void setRoll(double roll);
	double getRoll()const;
public:
	void setScale(double scale);
	double getScale()const;

	virtual double getDefaultScale()const {return 1.0f;}
	void resetScale()
	{
		double scale = getDefaultScale();
		if(scale != getScale())
			setScale(scale);
	}
public:
    virtual void update();
private:
    GeoEntityPrivate* priv = nullptr;
};

#endif